/*
 * Arguments.c
 *
 *  Created on: 3 mars 2012
 *      Author: Jeff
 */

#include <Arduino.h>
#include "ArgumentHandler.hpp"

ArgumentHandler::ArgumentHandler() {
	argumentTypes = NULL;
	argumentCount = 0;
};

void ArgumentHandler::registerAll(struct Argument * arg, int count) {
	argumentTypes = arg;
	argumentCount = count;
};

void * ArgumentHandler::parseArgument(int argIndex, char * str) {
	return(argumentTypes[argIndex].parse(str));
};
